import 'package:flutter/material.dart';

class FullScreenMediaquery extends StatefulWidget {
  FullScreenMediaquery({Key key}) : super(key: key);

  @override
  _FullScreenMediaqueryState createState() => _FullScreenMediaqueryState();
}

class _FullScreenMediaqueryState extends State<FullScreenMediaquery> {
  @override
  Widget build(BuildContext context) {
    final double topPadding = MediaQuery.of(context).padding.top;
    final double bottomPadding = MediaQuery.of(context).padding.bottom;
    return Container(
      padding: EdgeInsets.fromLTRB(0, topPadding, 0, bottomPadding),
      color: Colors.white,
      child: Column(
        mainAxisAlignment: MainAxisAlignment.spaceBetween,
        children: [
          Container(
            color: Colors.lightBlue,
            child: Text("顶部"),
          ),
          Container(
            color: Colors.lightBlue,
            child: Text("底部"),
          ),
        ],
      ),
    );
  }
}
